package IO流.缓冲流.BufferedRead.Test02;

import java.io.*;

public class BufferedReadTest02 {
    public static void main(String[] args) {
        /*
        FileInputStream in = null;
        InputStreamReader reader = null;
        try {
            in = new FileInputStream("D:\\Desktop\\IDEA\\javase\\src\\IO流\\文件复制演示\\Test02\\CopyTest02.java");
            reader = new InputStreamReader(in);

        } catch (FileNotFoundException e) {
            e.printStackTrace();
        }
        */
        BufferedReader br = null;
        try {
            br = new BufferedReader(new InputStreamReader(new FileInputStream("D:\\Desktop\\IDEA\\javase\\src\\IO流\\文件复制演示\\Test02\\CopyTest02.java")));
        } catch (FileNotFoundException e) {
            e.printStackTrace();
        }
        String line = null;

        try {
            while((line = br.readLine()) != null){
                System.out.println(line);
            }
            br.close();
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
